<!doctype html>
<html xmlns:th="http://www.thymeleaf.org">
<head>
    <meta charset="UTF-8">
    <title>后台管理</title>
    <link rel="stylesheet" type="text/css" href="css/common.css"/>
    <link rel="stylesheet" type="text/css" href="css/main.css"/>
    <script type="text/javascript" src="js/libs/modernizr.min.js"></script>
	<script type="text/javascript" src="js/public.js"></script>
	<script>
		window.onload = function (){
			var token = sessionStorage.getItem("token");
			if(token == null){
				window.location.href = "/shop/login.html";
			}
			var consumerName = sessionStorage.getItem("consumerName");
			var role = "店长";
			if(sessionStorage.getItem("role") != "1"){
							  role = "店员";
			}
			document.getElementById("manager_name").innerText = role+":"+consumerName;
			// id="consumerName"
			// id="role" type="t
			// id="tele" type="t
			// id="email" type="
			document.getElementById("consumerName").value = sessionStorage.getItem("consumerName");
			document.getElementById("role").innerText =role;
			document.getElementById("tele").value =sessionStorage.getItem("phone");
			document.getElementById("email").value =sessionStorage.getItem("email");
			
		}
		function managerChange(){
			var consumerName = document.getElementById("consumerName").value;
			var role = 1;
			// if(document.getElementById("role").value == "店员"){role = 2;}
			var phone = document.getElementById("tele").value;
			var email = document.getElementById("email").value;
			alert("修改成功");
		}
	</script>
</head>
<body>
<div class="topbar-wrap white">
    <div class="topbar-inner clearfix">
        <div class="topbar-logo-wrap clearfix">
            <h1 class="topbar-logo none"><a href="admin.html" class="navbar-brand">后台管理</a></h1>
            <ul class="navbar-list clearfix">
                <li><a class="on" href="admin.html">后台管理首页</a></li>
            </ul>
        </div>
        <div class="top-info-wrap">
            <ul class="top-info-list clearfix">
                <li><a href="store.html" id= "manager_name">管理员</a></li>
                <li><a href="password.html">修改密码</a></li>
                <li><a href="#" onclick="logout()">退出</a></li>
            </ul>
        </div>
    </div>
</div>
<div class="container clearfix">
    <div class="sidebar-wrap">
        <div class="sidebar-title">
            <h1>菜单</h1>
        </div>
        <div class="sidebar-content">
            <ul class="sidebar-list">
                <li>
                    <a href="#"><i class="icon-font">&#xe003;</i>常用操作</a>
                    <ul class="sub-menu">
                        <li><a href="product.html"><i class="icon-font">&#xe008;</i>商品管理</a></li>
                        <li><a href="order.html"><i class="icon-font">&#xe005;</i>订单管理</a></li>
						<li><a href="insert.html"><i class="icon-font">&#xe005;</i>商品新增</a></li>
						<li><a href="category.html"><i class="icon-font">&#xe005;</i>类型管理</a></li>
                    </ul>
                </li>
                <li>
                    <a href="#"><i class="icon-font">&#xe018;</i>系统管理</a>
                    <ul class="sub-menu">
                        <li><a href="store.html"><i class="icon-font">&#xe017;</i>店铺信息设置</a></li>
						<li><a href="manager.html"><i class="icon-font">&#xe017;</i>个人信息设置</a></li>
						<li><a href="members.html"><i class="icon-font">&#xe017;</i>店铺成员信息</a></li>
                    </ul>
                </li>
            </ul>
        </div>
    </div>
    <!--/sidebar-->
    <div class="main-wrap">
        <div class="result-wrap">
            <div class="result-title">
                <h1>个人信息设置</h1>
            </div>
            <div class="result-content">
                <ul class="sys-info-list">
                    <li>
                        <label class="res-lab">姓名</label><input class="res-info" id="consumerName" type="text" value=""/><br />
						<label class="res-lab">身份</label><span class="res-info" id="role"></span><br />
						<label class="res-lab">电话</label><input class="res-info" id="tele" type="text" value=""/><br />
						<label class="res-lab">邮箱</label><input class="res-info" id="email" type="text" value=""/><br />
						<label class="res-lab"></label><input class="res-info"  type="button" value="修改" onclick="managerChange()"/><br />
                    </li>
                </ul>
            </div>
        </div>
    </div>
    <!--/main-->
</div>
<style>
.copyrights{text-indent:-9999px;height:0;line-height:0;font-size:0;overflow:hidden;}
</style>
</body>
</html>